﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _97判断整数数组是否包含某数
{
    internal class Program
    {
        private static void Main(string[] args)
        {
            int[] array = { 8, 4, 6, 1, 9, 3, 4 };
            Console.WriteLine("请输入一个数字:");
            int n = int.Parse(Console.ReadLine());
            bool b = false;//假设没有
            for (int i = 0; i < array.Length; i++)
            {
                if (array[i] == n)
                {
                    b = true;
                    break;
                }
            }
            Console.WriteLine(b);
        }
    }
}